package org.app;

import com.typesafe.config.Config

import collection.JavaConversions._

case class KafkaSettings(address: String, groups:Array[String])

object KafkaSettings {
  def apply(config: Config): KafkaSettings =
    KafkaSettings(config.getString("kafka.endpoint"),config.getStringList("kafka.groups").toList.toArray)
}

case class InfluxSettings(host: String, port:Int, interval:Int)

object InfluxSettings {
  def apply(config: Config): InfluxSettings =
    InfluxSettings(config.getString("influx.host"),config.getInt("influx.port"),config.getInt("influx.interval"))
}